package com.xsmart.oa.api.mall.mymenu;

import com.xsmart.common.entity.RequestBean;
import com.xsmart.oa.services.mall.mymenu.RegisterService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;

@RestController
@RequestMapping("/api")
public class RegisterController {
    @Autowired
    RegisterService registerService;


    @RequestMapping(value = "/v1/RegisterService/register", method = RequestMethod.POST)
    public Object register(@ModelAttribute RequestBean requestBean, HttpServletRequest request) {
        return registerService.register(requestBean);
    }

    @RequestMapping(value = "/v1/RegisterService/wxRegister", method = RequestMethod.POST)
    public Object wxRegister(@ModelAttribute RequestBean requestBean, HttpServletRequest request) {
        return registerService.wxregister(requestBean);
    }
}
